<?php
use zhtfrontend\assets\LoginAsset;
use yii\helpers\Html;
use yii\widgets\ActiveForm;

LoginAsset::register($this);
$this->title = '登录 - 后台管理系统'
?>
<?php $this->beginPage() ?>
    <!DOCTYPE html>
    <html lang="<?= Yii::$app->language ?>">
    <head>
        <meta charset="<?= Yii::$app->charset ?>">
        <?= Html::csrfMetaTags() ?>
        <title><?= Html::encode($this->title) ?></title>
        <?php $this->head() ?>
    </head>
    <body onload="javascript:document.getElementById('loginform-username').focus();">
    <?php $this->beginBody() ?>
    <div id="login">
        <div class="content">
            <div class="top" style="width: 100%; height: 258px;background:url('<?= $imgs['background_img'] ?>') no-repeat;"></div>
            <div class="center">
                <img class="logo" src="<?= $imgs['logo'] ?>"/>
                <p><?= \yii\helpers\Html::encode(\common\components\helpers\Fun::getSiteName()); ?>后台管理系统登录</p>
                <?php $form = ActiveForm::begin(['id' => 'login-form']); ?>
                <div class="dl_form">
                    <div class="form-group">
                        <?= $form->field($model, 'username', ['template' => '{input}'])->textInput(['placeholder' => '请输入用户名']) ?>
                    </div>
                    <div class="form-group">
                        <?= $form->field($model, 'password', ['template' => '{input}'])->passwordInput(['placeholder' => '请输入密码', 'maxlength' => '50']) ?>
                    </div>
                    <?= $form->field($model, 'password', ['template' => '<div class="error-message" >{error}</div>']) ?>
                </div>
                <div class="button"><?= Html::submitButton('登&nbsp;&nbsp;录', ['name' => 'login-button']) ?></div>
                <?php ActiveForm::end(); ?>
            </div>
        </div>
    </div>
    <div class="yx-index-copyright">copyright &copy; 豆苗朵文化集团有限公司</div>
    <?php $this->endBody() ?>
    </body>
    </html>
<?php $this->endPage() ?>